package com.my.library.entity;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import com.my.library.annotation.MyTable;

@MyTable("app")
public class Application extends BaseModel {
	private int id;
	private String name;
	private String url;
	private Application parent;
	private Set<Application> children = new HashSet<Application>();
	/**
	 * @return the id
	 */
	public int getId() {
		return id;
	}
	/**
	 * @param id the id to set
	 */
	public void setId(int id) {
		this.id = id;
	}
	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}
	/**
	 * @param name the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}
	/**
	 * @return the url
	 */
	public String getUrl() {
		return url;
	}
	/**
	 * @param url the url to set
	 */
	public void setUrl(String url) {
		this.url = url;
	}
	/**
	 * @return the parent
	 */
	public Application getParent() {
		return parent;
	}
	/**
	 * @param parent the parent to set
	 */
	public void setParent(Application parent) {
		this.parent = parent;
	}
	/**
	 * @return the children
	 */
	public Set<Application> getChildren() {
		return children;
	}
	/**
	 * @param children the children to set
	 */
	public void setChildren(Set<Application> children) {
		this.children = children;
	}
}
